import request from '@/utils/request'
import { legalApiUrl } from '@/api/config'
// 执行案件管理页面接口

export function getList(data) {
    return request({
        url: legalApiUrl + '/lawmanage/case/management/list',
        method: 'post',
        data
    })
}

export function getDetail(params) {
    return request({
        url: legalApiUrl + '/lawmanage/case/management/details',
        method: 'get',
        params
    })
}

export function addData(data) {
    return request({
        url: legalApiUrl + '/lawmanage/case/management/insertExecutionCase',
        method: 'post',
        data
    })
}

export function editData(data) {
    return request({
        url: legalApiUrl + '/lawmanage/case/management/editExecutionCase',
        method: 'post',
        data
    })
}

export function exportData(data) {
    return request({
        url: legalApiUrl + '/lawmanage/case/management/export',
        method: 'post',
        data
    })
}

/**
 * 新增批注
 */
 export function addComment(data) {
    return request({
        url: legalApiUrl + '/lawmanage/case/management/addPostil',
        method: 'post',
        data
    })
}

/**
 * 编辑批注
 */
export function editComment(data) {
    return request({
        url: legalApiUrl + '/lawmanage/case/management/editPostil',
        method: 'post',
        data
    })
}

/**
 * 删除批注
 */
export function deleteComment(data) {
    return request({
        url: legalApiUrl + '/lawmanage/case/management/deletePostil',
        method: 'post',
        data
    })
}

/**
 * 推送批注
 */
 export function pushComment(data) {
    return request({
        url: legalApiUrl + '/lawmanage/case/management/postilPush',
        method: 'post',
        data
    })
}

/**
 * 新增进展情况 
 */
export function addProgress(data) {
    return request({
        url: legalApiUrl + '/lawmanage/case/management/addProcess',
        method: 'post',
        data
    })
}

/**
 * 编辑进展情况 
 */
export function editProgress(data) {
    return request({
        url: legalApiUrl + '/lawmanage/case/management/editProcess',
        method: 'post',
        data
    })
}

/**
 * 删除进展情况 
 */
export function deleteProgress(data) {
    return request({
        url: legalApiUrl + '/lawmanage/case/management/deleteProcess',
        method: 'post',
        data
    })
}

/**
 * 销项
 */
export function destroyLetter(data) {
    return request({
        url: legalApiUrl + '/lawmanage/case/management/destroy',
        method: 'post',
        data
    })
}

/**
 * 获取处理推送时的详情信息
 */
export function getCommentDetailByApproval(params) {
    return request({
        url: legalApiUrl + '/lawmanage/case/management/approveDetails',
        method: 'get',
        params,
    })
}